function [probs logprobs] = gmmprobRobust(mix, Y)


K = mix.ncentres;
N = size(Y, 1);

[act logact] = gmmactivRobust(mix, Y);
log_priors = log(mix.priors);

logpost = ones(N, 1)*log_priors + logact;


logprobs = zeros(N, 1);
for n = 1:N
    logprobs(n) = log(sum(exp(logpost(n, :)-max(logpost(n, :)))))+max(logpost(n, :));
end
probs = exp(logprobs);
